using System;

namespace FB.WinForms.Controls
{
	/// <summary>
	/// Specifies a HTML tag for a <see cref="ElementType"/> property.
	/// </summary>
	/// <remarks>
	/// The attribute is used to allow the HTML tags defined by <see cref="ElementType"/> to be associated with a more
	/// friendly name, e.g. &lt;A&gt; with Anchor
	/// </remarks>
	[AttributeUsage(AttributeTargets.Field)]
	internal sealed class TagAttribute : Attribute 
	{
		/// <summary>
		/// Represents the HTML tag.
		/// </summary>
		private string mTag;

		/// <summary>
		/// Initializes a new instance of the TagAttribute class.
		/// </summary>
		/// <param name="tag">The HTML tag.</param>
		public  TagAttribute(string tag)
		{
			mTag = tag;
		}

		/// <summary>
		/// Gets the HTML tag.
		/// </summary>
		public string Tag
		{
			get {return mTag;}        
		}
	}
}
